package com.ljz.service;

import com.ljz.api.bean.SpuBean;
import com.ljz.common.dao.MyBaseService;
import com.ljz.common.dao.bean.PageResult;
import com.ljz.entity.Spu;
import com.ljz.query.SpuQuery;

import java.util.List;
import java.util.Map;

public interface SpuService extends MyBaseService<Spu> {

    /**
     * 分页查找商品信息
     * @param spuQuery
     * @return
     */
    PageResult<Map> querySpuByPage(SpuQuery spuQuery);


    /**
     * 根据id查找商品所有信息
     * @param id
     * @return
     */
    Map querySpuById(Long id);


    /**
     * 更新商品库存
     * @param spuBeanList
     * @return
     */
    int updateSpuStock(List<SpuBean> spuBeanList);
}
